/*
 * @Author: fisher
 * @Date: 2023-08-01 14:55:48
 * @LastEditTime: 2024-01-09 16:20:38
 * @LastEditors: fisher
 * @Description:
 * @FilePath: \front-end-template\src\modules\DataManage\templates\api.js
 */
import request from "@/utils/request";
/**
 * @description: 查询数据仓库
 * @param {*} data
 * @param {*} params
 * @return {*}
 */
export function getWarehouseList(data, params) {
  return request({
    method: "post",
    url: "/converter/warehouse/queryPageList",
    data,
    params,
  });
}
/**
 * @description: 添加数据仓库
 * @param {*} data
 * @return {*}
 */
export const addWarehouse = (data) => {
  return request({
    method: "post",
    url: "/converter/warehouse/add",
    data,
  });
};

/**
 * @description: 删除数据仓库
 * @param {*} data
 * @return {*}
 */
export const deleteWarehouses = (data) => {
  return request({
    method: "post",
    url: "/converter/warehouse/deleteBatch",
    data,
  });
};

/**
 * @description: 获取模板
 * @param {*} data
 * @return {*}
 */
export const getTemplates = (data, params) => {
  return request({
    method: "post",
    url: "/converter/fmeTemplate/queryPageList",
    data,
    params,
  });
};

/**
 * @description: 删除数据仓库
 * @param {*} data
 * @return {*}
 */
export const deleteTemplates = (data) => {
  return request({
    method: "post",
    url: "/converter/fmeTemplate/deleteBatch",
    data,
  });
};

/**
 * @description: 上传模板文件
 * @param {*} data
 * @return {*}
 */
export const uploadTemplate = (data) => {
  return request({
    method: "post",
    url: "/converter/fmeTemplate/uploadTemplate",
    data,
  });
};

/**
 * @description: 添加模板数据
 * @param {*} data
 * @return {*}
 */
export const addTemplate = (data) => {
  return request({
    method: "post",
    url: "/converter/fmeTemplate/add",
    data,
  });
};

/**
 * @description: 修改模板信息
 * @param {*} data
 * @return {*}
 */
export const editTemplate = (data) => {
  return request({
    method: "post",
    url: "/converter/fmeTemplate/update",
    data,
  });
};
